﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace JESAI.Application.Abstractions.Sys.Dtos
{
    public class DataSourceColumnDto
    {
        public string Id { get; set; }

        /// <summary>
        /// 字段
        /// </summary>
        public string Columns { get; set; }

        /// <summary>
        /// 字段描述
        /// </summary>
        public string Name { get; set; }

        /// <summary>
        /// 字段数据类型
        /// </summary>
        public DataType DataType { get; set; }

        /// <summary>
        /// 数据长度
        /// </summary>
        public int? DataLength { get; set; }

        /// <summary>
        /// 字段可空
        /// </summary>
        public bool IsAllowNull { get; set; }

        /// <summary>
        /// 序号
        /// </summary>
        public int SortNum { get; set; }

        /// <summary>
        /// 是否有效
        /// </summary>
        public bool IsValid { get; set; }

        /// <summary>
        /// 是否主键
        /// </summary>
        public bool IsPrimaryKey { get; set; }

        /// <summary>
        /// 是否唯一键
        /// </summary>
        public bool IsUniqueKey { get; set; }
    }
}
